<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<script src="jquery-2.1.1.min.js"></script>

</head>
<body>
	<div class="myclass">
		<p>Test</p>
		<p name='tt'>TTT</p>

	</div>
		<p>------------</p>
	    <input type="radio" name="radio" id="radio1" value="1" />1  
	    <input type="radio" name="radio" id="radio2" value="2" />2  
	    <input type="radio" name="radio" id="radio3" value="3" />3  
	    <input type="radio" name="radio" id="radio4" value="4" />4  
	    <a href=""></a>
	    <button onclick="text()">test</button>
	    <p>TTT</p>
	<script>
		$('div').append($('input[type="radio"]'))
		function text () {
			var a = $("input[type='radio']:checked").val();
	
		if (!a) {
			$("input[type='radio'][value='3']").attr('checked', 'checked');
		};
		
		}
	</script>
</body>
</html>